﻿using System;
using System.Runtime.Serialization;

namespace TaskManager.Domain.Exceptions
{
    /// <summary>
    /// Exception that is raised when business rule violated
    /// </summary>
    public class UserActionFailureException : Exception
    {
        /// <summary>
        /// Parameterless constructor
        /// </summary>
        public UserActionFailureException()
        {
        }

        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="message">Error message</param>
        public UserActionFailureException(string message) : base(message)
        {
        }

        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="message">Error message</param>
        /// <param name="innerException">Inner exception</param>
        public UserActionFailureException(string message, Exception innerException) : base(message, innerException)
        {
        }

        /// <summary>
        /// Protected constructor
        /// </summary>
        /// <param name="info">Serialization info</param>
        /// <param name="context">Serialization context</param>
        protected UserActionFailureException(SerializationInfo info, StreamingContext context) : base(info, context)
        {
        }
    }
}